package com.bosssoft.goods.config;

import cn.hutool.core.lang.Snowflake;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import java.util.Date;

/**
 * 雪花算法配置类
 * @author 方_Sir
 * @date 2021-03-11
 */
@Configuration
public class SnowflakeConfig {

    @Bean
    public Snowflake snowflake(){
        return new Snowflake(new Date(1618915005672L),4, 20,false);
    }
}
